<!DOCTYPE html>

<html>
    <head>
        <meta charset="UTF-8">
        <title>随机</title>
        <style type="text/css">
            .wrapper { overflow: hidden ; border: 1px solid blue ; }
            .wrapper>span { float: left ; margin: 10px ; border: 1px solid green ; }
        </style>
    </head>
    <body>

        {{ rand }}

        <hr>

        {% if rand > 0.5 %}
        <div>大于0.5</div>
        {% endif %}

        <hr>

        {% for a in array %}
            <div>{{a.toString()}}</div>
        {% endfor %}

        <hr>

        {% for name,gender,age in array %}
            <div class="wrapper">
                <span>{{name}}</span>
                <span>{{gender}}</span>
                <span>{{age}}</span>
                <span>{{loop.index}}</span>
            </div>
        {% endfor %}

        <hr>

        {% if student %}

            {% for property, value in student %}

                <div class="wrapper">
                    <span> {{ property }} </span>
                    <span> = </span>
                    <span> {{ value }} </span>
                    <span>{{loop.index}}</span>
                </div>

            {% endfor %}

        {% endif %}
        
    </body>
</html>